Subtyping Union Types

نویسنده

  • Jérôme Vouillon
چکیده

Subtyping of union types can be fairly complex due to interactions with function and pair types. Furthermore, this interaction turns out to depend on the calculus considered: for instance, a call-by-value calculus and a call-by-name calculus will have different possible subtyping rules. In order to abstract ourselves away from this dependence, we consider a fairly large family of calculi. We define types in a semantic fashion, as sets of terms. Then, a type can be a subtype of another type if its denotation is included in the denotation of the other type. Using inference rules, we specify a subtyping relation which is both sound and complete with respect to the family of calculi. We expect this framework to allow the study of subtyping relations that only hold for some classes of calculi by restricting the family considered, and to allow the study of subtyping relations for richer type systems by enriching the family.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Encoding CDuce in the Cπ-calculus?

CDuce is a functional programming language featuring overloaded functions and a rich type system with recursive types, subtyping, union, negation and intersection types. The boolean constructors have a set-theoretic behaviour defined via a semantic interpretation of the types. The Cπ-calculus is an extension of the π-calculus that enriches Pierce and Sangiorgi π-calculus subtyping with union, i...

متن کامل

A Coalgebraic Foundation for Coinductive Union Types

This paper introduces a coalgebraic foundation for coinductive types, interpreted as sets of values and extended with set theoretic union. We give a sound and complete characterization of semantic subtyping in terms of inclusion of maximal traces. Further, we provide a technique for reducing subtyping to inclusion between sets of finite traces, based on approximation. We obtain inclusion of tre...

متن کامل

Subtyping with Union Types, Intersection Types and Recursive Types II

This paper is a follow-up on previous work by the author on subtyping with (set-theoretic) union, intersection and recursive types. Previously, it was shown how types may be encoded as regular tree expressions/set constraints. This gave rise to a sound and complete decision procedure for type inclusion. The result was, however, limited to a rather speciic type language. In the work reported on ...

متن کامل

Logic of subtyping

We introduce new modal logical calculi that describe subtyping properties of Cartesian product and disjoint union type constructors as well as mutually-recursive types defined using those type constructors. Basic Logic of Subtyping S extends classical propositional logic by two new binary modalities ⊗ and ⊕. An interpretation of S is a function that maps standard connectives into set-theoretica...

متن کامل

Semantic subtyping between coinductive mutable record types with unions and intersections

Semantic subtyping between coinductive record types supports accurate type analysis of object-oriented languages, by introducing Boolean type constructors and modeling cyclic objects. In previous work, a sound and complete algorithm for semantic subtyping has been proposed, but only for coinductive immutable record types with unions. In this work we address the issue of extending the previous r...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2004